/**
 * 优惠券
 *
 * @typedef {'default'|'useless'|'disabled'} CouponCardStatus
 * @typedef {'discount'|'price'} CouponCardType
 *
 * @param {number} [id]
 * @param {CouponCardStatus} [status]
 * @param {CouponCardType} [type]
 */
export function getCoupon(id = 0, status = '0', type = (id % 2) + 1) {
  return {
    id: `${id}`,
    status,
    money: 5000,
    name: '拍卖名称拍卖名称拍卖名称拍卖名称',
    createTime: '2023-10-22 00:00:00',
    applyTime: '2023-10-23 00:00:00',
    refundTime: '2023-10-23 00:00:00'
  };
}

/** 优惠券列表 */
export function getCouponList(status = 'default', length = 10) {
  return new Array(length).fill(0).map((_, idx) => getCoupon(idx, status));
}
